#include <stdio.h>

#include "SaveManager.h"
#include "Map.h"
#include "Object.h"

void LoadSaveFile(char* fileName)
{
    int i;
    int objCount;
    FILE* file;

    file = fopen(fileName, "r");

    // Chargement de la map
    LoadMap(file);
    
    // Chargement des objets
    objCount = fgetc(file);
    objCount |= fgetc(file) << 8;
    for (i = 0; i < objCount; i++)
        LoadObject(file);

    fclose(file);
}
